#ifndef SPRITE_H
#define SPRITE_H

#include <Windows.h>
#include <MMSystem.h>
#include <stdio.h>
#include "PhysicsObject.h"

class Sprite
{
	public:
		// function handles loading image and setting default x, y position
		void Initialise(HDC* bHDC, LPSTR filename, int xpos, int ypos, float sWidth, float sHeight, float mass, float e, bool hit);

		//Over loaded draw fuctions for each of the diffrent Blt
		//No paramters for stantartl BitBlt
		//Three int for the transparent colour R,G,B
		//Two floats for scale width and height
		//Six ints for the three points of the parallelogram
		void drawSprite();
		void drawSprite(int, int, int);
		void drawSprite(float, float);
		void drawSprite(int, int, int, int, int, int);

		inline void setSpriteX(int xpos) { x = xpos; };
		inline void setSpriteY(int ypos) { y = ypos; };
		inline void setSpriteWidth(int w){ width = w; };
		inline void setSpriteHeight(int h){ height = h; };
		inline void setSpriteScaleWidth(int sw){scaleWidth = sw; };
		inline void setSpriteScaleHeight(int sh){scaleWidth = sh; };

		inline int getSpriteX(){ return x; };
		inline int getSpriteY(){ return y; };
		inline int getSpriteWidth() { return width; };
		inline int getSpriteHeight() { return height; };
		inline float getSpriteScaleWidth(){ return scaleWidth; };
		inline float getSpriteScaleHeight(){ return scaleHeight;  };

		PhysicsObject RigidBody;
		inline void setRigidBody(PhysicsObject rigidbody){ RigidBody = rigidbody; };
		inline PhysicsObject getRigidBody(){ return RigidBody; };

	protected:
		void		LoadABitmap(LPSTR);// function for loading bitmap
		int			x, y, width, height;// variables for storing position and size
		float		scaleWidth, scaleHeight;
		HDC			bitmapHDC;
		HDC*		backHDC;
		HBITMAP		bitmap;// variable for storing handle to image
};
#endif